package de.dhbw.ka.tit09.picsim;

import java.util.EventObject;

/**
 * State event class. Describes the event which occurs when the execution status
 * changes.
 * 
 * @author Andreas Bender
 * 
 */
public class StateEvent extends EventObject {
	private static final long serialVersionUID = 2870232631694623617L;

	private ExecStatus status;

	/**
	 * Constructor.
	 * 
	 * @param source the object where the event occurred
	 * @param status the current execution state
	 */
	public StateEvent(Object source, ExecStatus status) {
		super(source);
		this.status = status;
	}

	/**
	 * Returns the current execution status.
	 * 
	 * @return the execution status
	 */
	public ExecStatus getStatus() {
		return status;
	}
}
